Create Chat From ZIP
Creates a new chat from a zip archive.
Usage
import { v0 } from 'v0'const result = await v0.chats.createFromZip({ url: 'https://example.com',})console.log(result)From ZIP URL
import { v0 } from 'v0'const result = await v0.chats.createFromZip({ url: 'https://example.com/archive.zip', title: 'Imported project',})console.log(result)API Signature
Request
Request Body
Zip archive used to seed the new chat.
Visibility setting for the new chat.
Title for the new chat.
Arbitrary key-value data to attach to the chat.
Response
Unique chat identifier.
Chat title, if generated.
Visibility setting of the chat.
ISO timestamp of when the chat was created.
ISO timestamp of when the chat was last updated.
ID of the user who created the chat.
Associated Vercel project ID, if any.
User-defined key-value metadata.
Whether the caller has write access to this chat.
Token usage and credit cost for prompt.
Token counts for this message.
Prompt input value (non-cached).
Completion output value.
Cache-read input value.
Cache-write input value.
Sum of input, output, cacheRead, and cacheWrite.
Credit cost for this message.
Prompt input value (non-cached).
Completion output value.
Cache-read input value.
Cache-write input value.
Sum of input, output, cacheRead, and cacheWrite.
Create Chat From Repository
Creates a new chat from a GitHub repository.
Create Chat (Streaming)
Creates a new chat with a user message and returns a Server-Sent Events stream. Events include initial chat state, title deltas, content chunk deltas, and final chat state. The response is `text/event-stream`; each event is `data: <JSON>\n\n` where the JSON conforms to ChatStreamEvent.